﻿<%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl" %>
<% using (Ajax.BeginForm("Update", "RuongMuoiNha", new AjaxOptions { UpdateTargetId = "list_RuongMuoiNha" }, new { name = "FormRuongMuoiNha" }))
   {
       %>
        <%: Html.TextBox("ruongmuoi_edit", (string)ViewData["ruongmuoi_sendedit"], new { style = "display:none;" })%>
        <%: Html.TextBox("nguoilam_edit", (string)ViewData["nguoilam_sendedit"], new { style = "display:none;" })%>
        <%: Html.TextBox("noinhap_edit", (string)ViewData["noinhap_sendedit"], new { style = "display:none;" })%>
            <%: Html.TextBox("pagesize_edit", (string)ViewData["pagesize_sendedit"], new { style = "display:none;" })%>
            <%: Html.TextBox("page_edit", (string)ViewData["page_sendedit"], new { style = "display:none;" })%>
            <%
                Data.DBOES.RuongMuoiNha obj = (Data.DBOES.RuongMuoiNha)ViewData["DataRuongMuoiNha"];
       if (obj != null)
       {
       %>
           
        <table width="100%">
        <tr>
            <td style="padding-left:10px">Mã RMN:</td>
            <td><span class="AddNew"><input type="text"  name="IdRuongMuoiNha" value="<%= obj.IdRuongMuoiNha %>" readonly="readonly"/></span></td>
            <td>Ngày tháng:</td>
            <td><span class="AddNew"><input type="text"  name="NgayThang" id="NgayThang" class="datepicker" value="<%= obj.NgayThang %>"/></span></td>
            <td>Ruộng muối:</td>
            <td><span class="AddNew"><input type="text"  name="RuongMuoi" value="<%= obj.RuongMuoi %>"/></span></td>
        </tr>
        <tr>
            <td style="padding-left:10px">Người làm:</td>
            <td><span class="AddNew"><input type="text"  name="NguoiLam" value="<%= obj.NguoiLam %>"/></span></td>
            <td>Số xe:</td>
            <td><span class="AddNew"><input type="text"  name="SoXe" value="<%= obj.SoXe %>"/></span></td>
            <td>Số lượng</td>
            <td><span class="AddNew"><input type="text"  name="SoLuong" id="SoLuong" value="<%= obj.SoLuong %>"/></span></td>
        </tr>
         <tr>
            <td style="padding-left:10px">Đơn giá:</td>
            <td><span class="AddNew"><input type="text"  name="DonGia" id="DonGia" value="<%= obj.DonGia %>"/></span></td>
            <td>Ăn chia:</td>
            <td><span class="AddNew"><input type="text"  name="AnChia" id="AnChia" value="<%= obj.AnChia %>"/></span></td>
            <td>Nơi nhập :</td>
            <td><span class="AddNew"><input type="text"  name="NoiNhap"  value="<%= obj.NoiNhap %>"/></span></td>
        </tr>
         <tr>
            <td style="padding-left:10px">Diễn giải:</td>
            <td><span class="AddNew"><input type="text"  name="DienGiai" value="<%= obj.DienGiai %>"/></span></td>
            <td>Ghi chú:</td>
            <td><span class="AddNew"><input type="text"  name="GhiChu" value="<%= obj.GhiChu %>"/></span></td>
            <td></td>
            <td></td>
        </tr>
        <tr>
            <td colspan="6"><div class="Submit">
        	<ul>
            	<li class="Cancel"><a href="javascript:SubmitButton('cancle')">Hủy</a><input type="reset" style="display:none" name="btnCancel"/></li>
                <li class="Adds"><a href="javascript:SubmitButton('add')">Thêm</a><input type="submit" style="display:none" name="btnAdd" /></li>
            </ul>
        </div></td>
        </tr>
        </table>        
         
        <%
       }
       else
       { 
        %>
        <table width="100%">
         <tr>
            <td style="padding-left:10px">Mã RMN:</td>
            <td><span class="AddNew"><input type="text"  name="IdRuongMuoiNha" readonly="readonly"/></span></td>
            <td>Ngày tháng:</td>
            <td><span class="AddNew"><input type="text"  name="NgayThang" id="NgayThang" class="datepicker" /></span></td>
            <td>Ruộng muối:</td>
            <td><span class="AddNew"><input type="text"  name="RuongMuoi"/></span></td>
        </tr>
        <tr>
            <td style="padding-left:10px">Người làm:</td>
            <td><span class="AddNew"><input type="text"  name="NguoiLam"/></span></td>
            <td>Số xe:</td>
            <td><span class="AddNew"><input type="text"  name="SoXe"/></span></td>
            <td>Số lượng</td>
            <td><span class="AddNew"><input type="text"  name="SoLuong" id="SoLuong" /></span></td>
        </tr>
         <tr>
            <td style="padding-left:10px">Đơn giá:</td>
            <td><span class="AddNew"><input type="text"  name="DonGia" id="DonGia" /></span></td>
            <td>Ăn chia:</td>
            <td><span class="AddNew"><input type="text"  name="AnChia" id="AnChia" /></span></td>
            <td>Nơi nhập :</td>
            <td><span class="AddNew"><input type="text"  name="NoiNhap"/></span></td>
        </tr>
         <tr>
            <td style="padding-left:10px">Diễn giải:</td>
            <td><span class="AddNew"><input type="text"  name="DienGiai"/></span></td>
            <td>Ghi chú:</td>
            <td><span class="AddNew"><input type="text"  name="GhiChu"/></span></td>
            <td></td>
            <td></td>
        </tr>
        <tr>
            <td colspan="6"><div class="Submit">
        	<ul>
            	<li class="Cancel"><a href="javascript:SubmitButton('cancle')">Hủy</a><input type="reset" style="display:none" name="btnCancel"/></li>
                <li class="Adds"><a href="javascript:SubmitButton('add')">Thêm</a><input type="submit" style="display:none" name="btnAdd" /></li>
            </ul>
        </div></td>
        </tr>
        </table>        
         
        <%
       }
        
   }
    %>